
<template>
	<!-- 运费 -->
	<div class="product-freight mt-10">
		<p class="text-show-line-1">
			<span class="color-gray-light mr-60">运费</span>
			<span>{{ data.PostageTemplateTitle || "免运费" }}</span>
		</p>
		<div class="flex fs-20 flex-s-0">
			<div>
				<p v-show="ProductInfo.MinNum && ProductInfo.MinNum > 0">起售:{{ ProductInfo.MinNum }}</p>
				<p v-show="ProductInfo.LimitBuy && ProductInfo.LimitBuy > 0">限购:{{ ProductInfo.LimitBuy }}</p>
			</div>
			<div v-if="ProductInfo.StockStr && (SettingInfo.IsShowStock == 1 || SettingInfo.IsShowSaleCounts == 1)">
				<p v-show="ProductInfo.MinNum && ProductInfo.MinNum > 0" class="mlr-20">|</p>
				<p v-show="ProductInfo.LimitBuy && ProductInfo.LimitBuy > 0" class="mlr-20">|</p>
			</div>
			<div v-if="ProductInfo.StockStr">
				<p v-if="SettingInfo.IsShowStock == 1">{{ ProductInfo.StockStr }}</p>
				<p v-if="SettingInfo.IsShowSaleCounts == 1">近期销量:{{ ProductInfo.SaleCounts + ProductInfo.InitailSaleCounts }}</p>
			</div>
		</div>
	</div>
</template>

<script>
export default {
	name: 'ProductFreight',
	components: {
	},
	props: {
		data: { // 数据
			type: Object,
			required: true,
			default: function () {
				return {}
			}
		}
	},
	data() {
		return {
		}
	},
	computed: {
		ProductInfo() {
			const ProductInfo = this.data.ProductInfo || {}
			return ProductInfo
		},
		SettingInfo() {
			const SettingInfo = this.data.SettingInfo || {}
			return SettingInfo
		}
	},

	methods: {

	}
}
</script>

<style lang="scss" scoped>
// 运费
.product-freight {
	background: $colorF;
	@include flex-content(space-between, center);
	padding: 16px 32px;
	font-size: 26px;
}
</style>
